﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package Transactions {
    import Engine.Transactions.*;
    import Classes.*;
    import Modules.zoo.ui.*;

    public class TPurchaseRandomZooAnimal extends Transaction {

        protected var m_target:MechanicMapResource;
        protected var m_dialog:ZooDialogView;

        public function TPurchaseRandomZooAnimal(_arg1:MechanicMapResource, _arg2:ZooDialogView){
            this.m_target = _arg1;
            this.m_dialog = _arg2;
        }
        override public function perform():void{
            signedCall("GameMechanicService.performMechanicAction", this.m_target.getId(), "loot", "all", {});
        }
        override protected function onComplete(_arg1:Object):void{
            if (_arg1){
                this.m_dialog.onAnimalRolled(_arg1);
            };
            this.m_dialog = null;
        }

    }
}//package Transactions 
